<%@ include file="includes.jsp" %>
<%@ include file="header.jsp" %>

<div id="attacker">
<form id='attackerForm'>
    <ul>
        <li>
            <label>Unit name:</label>
            <input name="goodGuys.name" id="goodGuys.name" size="20" maxlength="80" />
        </li>
        <li>
            <label>Model count:</label>
            <input name="goodGuys.modelCount" id="goodGuys.modelCount" size="2" maxlength="2" />
        </li>
        <li>
            <label>Models in base contact: </label>
            <input name="goodGuys.fileSize" id="goodGuys.fileSize" size="2" maxlength="2" />
        </li>
        <li>
            <label>Static combat bonus: </label>
            <input name="goodGuys.staticCombatBonus" id="goodGuys.staticCombatBonus" size="2" maxlength="2" />
        </li>
        <li>
            <label>Musician: </label>
            <input type="checkbox" name="goodGuys.musician" id="goodGuys.musician" />
        </li>
        <li>
            <label>Reroll break test: </label>
            <input type="checkbox" name="goodGuys.rerollBreakTest" id="goodGuys.rerollBreakTest" />
        </li>
        <li>
            <label>Cold blooded: </label>
            <input type="checkbox" name="goodGuys.coldBlooded" id="goodGuys.coldBlooded" />
        </li>
        <li>
            <h3>Profile</h3>
            <ul>
		        <li><label for="goodGuys.profile.ws">WS</label><input name="goodGuys.profile.ws" id="goodGuys.profile.ws" size="2" maxlength="2" /></li>
		        <li><label for="goodGuys.profile.st">St</label><input name="goodGuys.profile.st" id="goodGuys.profile.st" size="2" maxlength="2" /></li>
		        <li><label for="goodGuys.profile.to">To</label><input name="goodGuys.profile.to" id="goodGuys.profile.to" size="2" maxlength="2" /></li>
		        <li><label for="goodGuys.profile.wo">Wo</label><input name="goodGuys.profile.wo" id="goodGuys.profile.wo" size="2" maxlength="2" /></li>
		        <li><label for="goodGuys.profile.at">At</label><input name="goodGuys.profile.at" id="goodGuys.profile.at" size="2" maxlength="2" /></li>
		        <li><label for="goodGuys.profile.ld">Ld</label><input name="goodGuys.profile.ld" id="goodGuys.profile.ld" size="2" maxlength="2" /></li>
		        <li><label for="goodGuys.profile.us">US</label><input name="goodGuys.profile.us" id="goodGuys.profile.us" size="2" maxlength="2" /></li>
		        <li><label for="goodGuys.profile.asv">ASv</label><input name="goodGuys.profile.asv" id="goodGuys.profile.asv" size="2" maxlength="2" /></li>
		        <li><label for="goodGuys.profile.wsv">WSv</label><input name="goodGuys.profile.wsv" id="goodGuys.profile.wsv" size="2" maxlength="2" /></li>
            </ul>
        <li>
        <li>
            <h3>Mount profile</h3>
            <ul>
		        <li><label for="goodGuys.mount.ws">WS</label><input name="goodGuys.mount.ws" id="goodGuys.mount.ws" size="2" maxlength="2" /></li>
		        <li><label for="goodGuys.mount.st">St</label><input name="goodGuys.mount.st" id="goodGuys.mount.st" size="2" maxlength="2" /></li>
		        <li><label for="goodGuys.mount.in">In</label><input name="goodGuys.mount.in" id="goodGuys.mount.in" size="2" maxlength="2" /></li>
		        <li><label for="goodGuys.mount.at">At</label><input name="goodGuys.mount.at" id="goodGuys.mount.at" size="2" maxlength="2" /></li>
            </ul>
        <li>
    </ul>
</form>
</div>
<div id="defender">
<form id="defenderForm">
    <ul>
        <li>
            <label>Unit name:</label>
            <input name="badGuys.name" id="badGuys.name" size="20" maxlength="80" />
        </li>
        <li>
            <label>Model count:</label>
            <input name="badGuys.modelCount" id="badGuys.modelCount" size="2" maxlength="2" />
        </li>
        <li>
            <label>Models in base contact: </label>
            <input name="badGuys.fileSize" id="badGuys.fileSize" size="2" maxlength="2" />
        </li>
        <li>
            <label>Static combat bonus: </label>
            <input name="badGuys.staticCombatBonus" id="badGuys.staticCombatBonus" size="2" maxlength="2" />
        </li>
        <li>
            <label>Musician: </label>
            <input type="checkbox" name="badGuys.musician" id="badGuys.musician" />
        </li>
        <li>
            <label>Reroll break test: </label>
            <input type="checkbox" name="badGuys.rerollBreakTest" id="badGuys.rerollBreakTest" />
        </li>
        <li>
            <label>Cold blooded: </label>
            <input type="checkbox" name="badGuys.coldBlooded" id="badGuys.coldBlooded" />
        </li>
        <li>
            <h3>Profile:</h3>
            <ul>
		        <li><label for="badGuys.profile.ws">WS</label><input name="badGuys.profile.ws" id="badGuys.profile.ws" size="2" maxlength="2" /></li>
		        <li><label for="badGuys.profile.st">St</label><input name="badGuys.profile.st" id="badGuys.profile.st" size="2" maxlength="2" /></li>
		        <li><label for="badGuys.profile.to">To</label><input name="badGuys.profile.to" id="badGuys.profile.to" size="2" maxlength="2" /></li>
		        <li><label for="badGuys.profile.wo">Wo</label><input name="badGuys.profile.wo" id="badGuys.profile.wo" size="2" maxlength="2" /></li>
		        <li><label for="badGuys.profile.at">At</label><input name="badGuys.profile.at" id="badGuys.profile.at" size="2" maxlength="2" /></li>
		        <li><label for="badGuys.profile.ld">Ld</label><input name="badGuys.profile.ld" id="badGuys.profile.ld" size="2" maxlength="2" /></li>
		        <li><label for="badGuys.profile.us">US</label><input name="badGuys.profile.us" id="badGuys.profile.us" size="2" maxlength="2" /></li>
		        <li><label for="badGuys.profile.asv">ASv</label><input name="badGuys.profile.asv" id="badGuys.profile.asv" size="2" maxlength="2" /></li>
		        <li><label for="badGuys.profile.wsv">WSv</label><input name="badGuys.profile.wsv" id="badGuys.profile.wsv" size="2" maxlength="2" /></li>
            </ul>
        </li>
        <li>
            <h3>Mount profile</h3>
            <ul>
                <li><label for="badGuys.mount.ws">WS</label><input name="badGuys.mount.ws" id="badGuys.mount.ws" size="2" maxlength="2" /></li>
                <li><label for="badGuys.mount.st">St</label><input name="badGuys.mount.st" id="badGuys.mount.st" size="2" maxlength="2" /></li>
                <li><label for="badGuys.mount.in">In</label><input name="badGuys.mount.in" id="badGuys.mount.in" size="2" maxlength="2" /></li>
                <li><label for="badGuys.mount.at">At</label><input name="badGuys.mount.at" id="badGuys.mount.at" size="2" maxlength="2" /></li>
            </ul>
        <li>
    </ul>
</form>
</div>
<div id="results">
<h1>WPD - Warhammer Probability Distribution</h1>

<ul>
    <li><input id="calculateCombatButton" type="button" value="Calculate combat!"/></li>
    <li><h2>Results</h2></li>
    <li>Good guys chance of breaking: <span id="probabilityGoodGuysBreak"/></li>
    <li>Bad guys chance of breaking: <span id="probabilityBadGuysBreak"/></li>
    <li>
        <h2>Combat result:</h2>
        <div id="combatResultContainer"></div>
    <li>
    <li>
        <h2>Good guys wounds caused:</h2>
        <div id="goodGuysWoundsCaused"></div>
    </li>
    <li>
        <h2>Bad guys wounds caused:</h2>
        <div id="badGuysWoundsCaused"></div>
    </li>
    <li>
        <h2>Static combat resolution:</h2>
        <div id="staticCombatResult"></div>
    </li>
</ul>
</div>

<%@ include file="footer.jsp" %>